package com.xgc.oauth.service.impl;

import com.xgc.oauth.entity.SysUser;
import com.xgc.oauth.mapper.SysUserMapper;
import com.xgc.oauth.service.ISysUserService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.Set;

/**
 * <p>
 * 用户表 服务实现类
 * </p>
 *
 * @author xgc
 * @since 2024-01-11
 */
@Service
public class SysUserServiceImpl extends ServiceImpl<SysUserMapper, SysUser> implements ISysUserService {

    @Autowired
    private SysUserMapper sysUserMapper;

    @Override
    public Set<String> getUserPermissions(Long userId) {
       return sysUserMapper.getUserPermissions(userId);
    }

    @Override
    public Set<String> getUserRoles(Long userId) {
        return sysUserMapper.getUserRoles(userId);
    }
}
